import request from "@/utils/request";


// 获取品牌列表
export function getBrandList(data) {
    return request({
        url: '/brand/getBrandList',
        method: 'post',
        data: data
    })
}

// 新增品牌
export function addNewBrand(data) {
    return request({
        url: '/brand/addBrand',
        method: 'post',
        data: data
    })
}

// 品牌详情
export function getBrandByBrandNum(data) {
    return request({
        url: '/brand/getBrandByBrandNum',
        method: 'post',
        data: data
    })
}

// 修改状态
export function setBrandStatus(data) {
    return request({
        url: '/brand/setBrandStatusByIdArr',
        method: 'put',
        data: data
    })
}

// 添加商品
export function addGoods(data) {
    return request({
        url: '/product/addProduct',
        method: 'post',
        data: data
    })
}

// 获取商品详情
export function detailsGoods(data) {
    return request({
        url: '/product/getProductByProductNum',
        method: 'post',
        data: data
    })
}

// 获取商品列表 - 分页获取
export function getGoodsList(data) {
    return request({
        url: '/product/getProductList',
        method: 'post',
        data: data
    })
}

// 启用禁用商品
export function disableGoods(data) {
    return request({
        url: '/product/setProductStatusByIdArr',
        method: 'put',
        data: data
    })
}

//产品线下拉列表
export function productLinePulldown(data) {
    return request({
        url: '/system/line/pulldown',
        method: 'post',
        data: data
    })
}
//系列下拉列表
export function productLineSeriesPulldown(data) {
    return request({
        url: '/system/line/seriesPulldown',
        method: 'post',
        data: data
    })
}

///system/line/productLineTree
// 产品线树菜单
export function productLineTree() {
    return request({
        url: '/system/line/productLineTree',
        method: 'get',
    })
}

///system/line/add  新增产品线
export function productLineAdd(data) {
    return request({
        url: '/system/line/add',
        method: 'post',
        data: data
    })
}

//修改产品线  /system/line/edit
export function productLineEdit(data) {
    return request({
        url: '/system/line/edit',
        method: 'post',
        data: data
    })
}

//产品线列表  /system/line/list/{id}
export function productLineList(data) {
    return request({
        url: `/system/line/list?pageNum=${data.pageNum}&pageSize=${data.pageSize}`,
        method: 'post',
        data: data
    })
}


//启用/禁用 system/line/operate
export function productLineOperate(data) {
    return request({
        url: '/system/line/operate',
        method: 'post',
        data: data
    })
}

//删除产品线 system/line/remove
export function productLineRemove(data) {
    return request({
        url: '/system/line/remove',
        method: 'post',
        data: data
    })
}

//获取关联商品详情 system/line/product
export function productLineDetails(data) {
    return request({
        url: `/system/line/product/list`,
        method: 'post',
        data: data
    })
}












































































